<template>
  <div>
    <a-card
      style="width: 100%"
      :tab-list="tabListNoTitle"
      :active-tab-key="titleKey"
      @tabChange="key => onTabChange(key)"
      :bordered="false"
      class="br-10"
    >
      <template v-if="titleKey === 'platform'">
        <MallPlatform />
      </template>
      <template v-else-if="titleKey === 'cooperation'">
        <MallCooperation />
      </template>
    </a-card>
  </div>
</template>

<script>
import MallPlatform from './mallPlatform.vue'
import MallCooperation from './mallCooperation.vue'

export default {
  components: {
    MallPlatform,
    MallCooperation
  },
  data() {
    return {
      tabListNoTitle: [],
      titleKey: 'platform'
    }
  },
  computed: {},
  watch: {},
  methods: {
    onTabChange(key) {
      this.titleKey = key
    }
  },
  created() {
    this.tabListNoTitle.push({
      tab: '资源平台配置',
      key: 'platform'
    })

    this.tabListNoTitle.push({
      tab: '跨界合作配置',
      key: 'cooperation'
    })
    this.titleKey = this.tabListNoTitle[0].key
  },
  mounted() {}
}
</script>

<style lang="less" scoped></style>
